-
Notifications
You must be signed in to change notification settings - Fork 188
feat: enhance CI pipeline with improved caching and multi-arch support #360
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: liuhy <[email protected]>
✅ Deploy Preview for vllm-semantic-router ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
👥 vLLM Semantic Team NotificationThe following members have been identified for the changed files in this PR and have been automatically assigned: 📁
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR enhances the CI pipeline by improving Docker build caching strategies and adding multi-architecture build support. The changes optimize build times through better layer caching and provide flexible multi-arch builds that can be skipped for PR builds to speed up CI feedback.
- Adds GitHub Actions cache integration for Docker builds with
cache-from
andcache-to
directives - Implements conditional multi-architecture support that skips arm64 builds for PRs while maintaining full multi-arch for releases
- Optimizes Dockerfile layers by separating dependency downloads from source code copying
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
File | Description |
---|---|
Dockerfile.extproc | Optimizes build layers with separate Go dependency download step and adds build optimizations |
.github/workflows/docker-publish.yml | Adds GitHub Actions caching, conditional multi-arch builds, and PR trigger paths |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
.github/workflows/docker-publish.yml
Outdated
- name: Set build parameters | ||
id: build-params | ||
run: | | ||
# Skip multi-arch for PRs to speed up CI, unless explicitly disabled |
Copilot
AI
Oct 8, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The comment is misleading. The logic actually skips multi-arch for PRs unless explicitly enabled (when skip_multiarch is false), not 'unless explicitly disabled'.
# Skip multi-arch for PRs to speed up CI, unless explicitly disabled | |
# Skip multi-arch for PRs to speed up CI, unless explicitly enabled |
Copilot uses AI. Check for mistakes.
.github/workflows/docker-publish.yml
Outdated
cache-to: type=gha,mode=max | ||
build-args: | | ||
BUILDKIT_INLINE_CACHE=1 | ||
CARGO_BUILD_JOBS=4 |
Copilot
AI
Oct 8, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hard-coding CARGO_BUILD_JOBS to 4 may not be optimal for all runner types. Consider using a dynamic value based on available CPU cores, such as CARGO_BUILD_JOBS=${{ github.event_name == 'pull_request' && '2' || '4' }}
.
CARGO_BUILD_JOBS=4 | |
CARGO_BUILD_JOBS=${{ github.event_name == 'pull_request' && '2' || '4' }} |
Copilot uses AI. Check for mistakes.
Signed-off-by: liuhy <[email protected]>
…MD64 Signed-off-by: liuhy <[email protected]>
Signed-off-by: liuhy <[email protected]>
…brary Signed-off-by: liuhy <[email protected]>
…brary Signed-off-by: liuhy <[email protected]>
… process Signed-off-by: liuhy <[email protected]>
… syntax Signed-off-by: liuhy <[email protected]>
Signed-off-by: liuhy <[email protected]>
…figuration Signed-off-by: liuhy <[email protected]>
…figuration Signed-off-by: liuhy <[email protected]>
…figuration Signed-off-by: liuhy <[email protected]>
…figuration Signed-off-by: liuhy <[email protected]>
Signed-off-by: liuhy <[email protected]>
…suffix Signed-off-by: liuhy <[email protected]>
Signed-off-by: liuhy <[email protected]>
…suffix Signed-off-by: liuhy <[email protected]>
…suffix Signed-off-by: liuhy <[email protected]>
@rootfs Hi, I believe I have completed this task. The build duration of the ARM architecture Docker image has been reduced to 20 minutes. I attempted to push a Docker image as part of the pull request workflow, but the PR does not have the necessary permissions to push images. If you have a moment, could you please review it again? |
@Aias00 thanks! merging it now for image build |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hi @Aias00 Why submit this document?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cargo.lock enables Docker layer caching optimization by ensuring deterministic dependency resolution. When Cargo.lock remains unchanged between builds, Docker can reuse the cached dependency compilation layer, significantly reducing build times from ~6.5 minutes to ~1.2 minutes for source code changes.
What type of PR is this?
enhance CI pipeline with improved caching and multi-arch support
What this PR does / why we need it:
Which issue(s) this PR fixes:
Fixes #359
Release Notes: Yes/No